﻿#ifndef CMDCREATETHREEDCLOUDMAP_H
#define CMDCREATETHREEDCLOUDMAP_H

#include "CommandManager/CommandBase.h"

namespace PostCommand
{
    /// @brief 后处理保存图像命令
    class CmdCreateThreeDCloudMap : public CommandManager::CommandBase
    {
        Q_OBJECT

    public:
        CmdCreateThreeDCloudMap();
        ~CmdCreateThreeDCloudMap();

        bool execute() override;
        void undo() override;
        void redo() override;

        void setUseNewWindow(bool useNewWindow) { m_useNewWindow = useNewWindow; }
        void setVariableIndex(int index) { m_variableIndex = index; }
        void setReaderIndex(int index) { m_readerIndex = index; }
        void setGraphType(int type) { m_graphType = type; }
        void setFilePath(const QString& path) { m_filePath = path; }
        void setName(const QString& name) { m_name = name; }
        void setGeometryFileName(const QString& geometryFileName) { m_geometryFileName = geometryFileName; }
        void setResultDataIndex(int index) { m_resultDataIndex = index; }

    private:
        bool m_useNewWindow{ true };
        int m_variableIndex{ -1 };
        int m_readerIndex{ -1 };
        int m_graphType{ 0 };
        QString m_filePath;
        QString m_name;
        QString m_geometryFileName{};
        int m_resultDataIndex{ -1 };
    };
} // namespace PostCommand

#endif
